package com.imc.core.config.redis;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

/**
 * Created by tanweiping on 2018/7/19.
 */
/*
* 类描述：redis对应的yml
* 开发者：tanweiping
* 创建日期：2018/8/7 10:26
*/
@Data
@Component
@ConfigurationProperties(prefix = "spring.redis")
public class RedisProperty {

    private boolean start;
    private int database;
    private String host;
    private int port;
    private int timeout;
    private String password;

    private Pool pool;

    @AllArgsConstructor
    @NoArgsConstructor
    @Data
    public static class Pool{
        private int maxActive;
        private int maxWait;
        private int maxIdle;
        private int minIdle;
    }
}
